Integrand size = 30, antiderivative size = 610 \[ \int (a+b x)^m (c+d x)^n \left (A+B x+C x^2+D x^3\right ) \, dx=\frac {\left (a^2 d^2 D \left (m^2+m (8+3 n)+3 \left (6+5 n+n^2\right )\right )+b^2 \left (c^2 D \left (6+5 m+m^2\right )-c C d (2+m) (4+m+n)+B d^2 \left (12+m^2+7 n+n^2+m (7+2 n)\right )\right )+a b d \left (c D (2+m) (6+m+3 n)-C d \left (m^2+m (8+3 n)+2 \left (8+6 n+n^2\right )\right )\right )\right ) (a+b x)^{1+m} (c+d x)^{1+n}}{b^3 d^3 (2+m+n) (3+m+n) (4+m+n)}-\frac {(a d D (9+2 m+3 n)+b (c D (3+m)-C d (4+m+n))) (a+b x)^{2+m} (c+d x)^{1+n}}{b^3 d^2 (3+m+n) (4+m+n)}+\frac {D (a+b x)^{3+m} (c+d x)^{1+n}}{b^3 d (4+m+n)}+\frac {\left (d (2+m+n) \left (a^3 d^2 D (1+n) (6+m+2 n)+a b^2 c (2+m) (c D (3+m)-C d (4+m+n))+A b^3 d^2 \left (12+m^2+7 n+n^2+m (7+2 n)\right )-a^2 b d (C d (1+n) (4+m+n)-c D (2+m) (6+m+3 n))\right )-(b c (1+m)+a d (1+n)) \left (a^2 d^2 D \left (m^2+m (8+3 n)+3 \left (6+5 n+n^2\right )\right )+b^2 \left (c^2 D \left (6+5 m+m^2\right )-c C d (2+m) (4+m+n)+B d^2 \left (12+m^2+7 n+n^2+m (7+2 n)\right )\right )+a b d \left (c D (2+m) (6+m+3 n)-C d \left (m^2+m (8+3 n)+2 \left (8+6 n+n^2\right )\right )\right )\right )\right ) (a+b x)^{1+m} (c+d x)^n \left (\frac {b (c+d x)}{b c-a d}\right )^{-n} \operatorname {Hypergeometric2F1}\left (1+m,-n,2+m,-\frac {d (a+b x)}{b c-a d}\right )}{b^4 d^3 (1+m) (2+m+n) (3+m+n) (4+m+n)} \]
(a^2*d^2*D*(m^2+m*(8+3*n)+3*n^2+15*n+18)+b^2*(c^2*D*(m^2+5*m+6)-c*C*d*(2+m )*(4+m+n)+B*d^2*(12+m^2+7*n+n^2+m*(7+2*n)))+a*b*d*(c*D*(2+m)*(6+m+3*n)-C*d *(m^2+m*(8+3*n)+2*n^2+12*n+16)))*(b*x+a)^(1+m)*(d*x+c)^(1+n)/b^3/d^3/(2+m+ n)/(3+m+n)/(4+m+n)-(a*d*D*(9+2*m+3*n)+b*(c*D*(3+m)-C*d*(4+m+n)))*(b*x+a)^( 2+m)*(d*x+c)^(1+n)/b^3/d^2/(3+m+n)/(4+m+n)+D*(b*x+a)^(3+m)*(d*x+c)^(1+n)/b ^3/d/(4+m+n)+(d*(2+m+n)*(a^3*d^2*D*(1+n)*(6+m+2*n)+a*b^2*c*(2+m)*(c*D*(3+m )-C*d*(4+m+n))+A*b^3*d^2*(12+m^2+7*n+n^2+m*(7+2*n))-a^2*b*d*(C*d*(1+n)*(4+ m+n)-c*D*(2+m)*(6+m+3*n)))-(b*c*(1+m)+a*d*(1+n))*(a^2*d^2*D*(m^2+m*(8+3*n) +3*n^2+15*n+18)+b^2*(c^2*D*(m^2+5*m+6)-c*C*d*(2+m)*(4+m+n)+B*d^2*(12+m^2+7 *n+n^2+m*(7+2*n)))+a*b*d*(c*D*(2+m)*(6+m+3*n)-C*d*(m^2+m*(8+3*n)+2*n^2+12* n+16))))*(b*x+a)^(1+m)*(d*x+c)^n*hypergeom([-n, 1+m],[2+m],-d*(b*x+a)/(-a* d+b*c))/b^4/d^3/(1+m)/(2+m+n)/(3+m+n)/(4+m+n)/((b*(d*x+c)/(-a*d+b*c))^n)
Time = 0.24 (sec) , antiderivative size = 254, normalized size of antiderivative = 0.42 \[ \int (a+b x)^m (c+d x)^n \left (A+B x+C x^2+D x^3\right ) \, dx=\frac {(a+b x)^{1+m} (c+d x)^n \left (\frac {b (c+d x)}{b c-a d}\right )^{-n} \left ((b c-a d)^3 D \operatorname {Hypergeometric2F1}\left (1+m,-3-n,2+m,\frac {d (a+b x)}{-b c+a d}\right )+b (b c-a d)^2 (C d-3 c D) \operatorname {Hypergeometric2F1}\left (1+m,-2-n,2+m,\frac {d (a+b x)}{-b c+a d}\right )+b^2 (b c-a d) \left (-2 c C d+B d^2+3 c^2 D\right ) \operatorname {Hypergeometric2F1}\left (1+m,-1-n,2+m,\frac {d (a+b x)}{-b c+a d}\right )+b^3 \left (c^2 C d-B c d^2+A d^3-c^3 D\right ) \operatorname {Hypergeometric2F1}\left (1+m,-n,2+m,\frac {d (a+b x)}{-b c+a d}\right )\right )}{b^4 d^3 (1+m)} \]
((a + b*x)^(1 + m)*(c + d*x)^n*((b*c - a*d)^3*D*Hypergeometric2F1[1 + m, - 3 - n, 2 + m, (d*(a + b*x))/(-(b*c) + a*d)] + b*(b*c - a*d)^2*(C*d - 3*c*D )*Hypergeometric2F1[1 + m, -2 - n, 2 + m, (d*(a + b*x))/(-(b*c) + a*d)] + b^2*(b*c - a*d)*(-2*c*C*d + B*d^2 + 3*c^2*D)*Hypergeometric2F1[1 + m, -1 - n, 2 + m, (d*(a + b*x))/(-(b*c) + a*d)] + b^3*(c^2*C*d - B*c*d^2 + A*d^3 - c^3*D)*Hypergeometric2F1[1 + m, -n, 2 + m, (d*(a + b*x))/(-(b*c) + a*d)] ))/(b^4*d^3*(1 + m)*((b*(c + d*x))/(b*c - a*d))^n)
Time = 1.04 (sec) , antiderivative size = 591, normalized size of antiderivative = 0.97, number of steps used = 6, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {2125, 1194, 27, 90, 80, 79}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int (a+b x)^m (c+d x)^n \left (A+B x+C x^2+D x^3\right ) \, dx\) |
\(\Big \downarrow \) 2125 |
\(\displaystyle \frac {\int (a+b x)^m (c+d x)^n \left (A d (m+n+4) b^3-(b c D (m+3)-b C d (m+n+4)+a d D (2 m+3 n+9)) x^2 b^2-\left (d D (m+3 n+6) a^2+2 b c D (m+3) a-b^2 B d (m+n+4)\right ) x b-a^2 D (b c (m+3)+a d (n+1))\right )dx}{b^3 d (m+n+4)}+\frac {D (a+b x)^{m+3} (c+d x)^{n+1}}{b^3 d (m+n+4)}\) |
\(\Big \downarrow \) 1194 |
\(\displaystyle \frac {\frac {\int b^2 (a+b x)^m (c+d x)^n \left (d^2 D (n+1) (m+2 n+6) a^3-b d (C d (n+1) (m+n+4)-c D (m+2) (m+3 n+6)) a^2+b^2 c (m+2) (c D (m+3)-C d (m+n+4)) a+A b^3 d^2 \left (m^2+(2 n+7) m+n^2+7 n+12\right )+b \left (\left (D \left (m^2+5 m+6\right ) c^2-C d (m+2) (m+n+4) c+B d^2 \left (m^2+(2 n+7) m+n^2+7 n+12\right )\right ) b^2+a d \left (c D (m+2) (m+3 n+6)-C d \left (m^2+(3 n+8) m+2 \left (n^2+6 n+8\right )\right )\right ) b+a^2 d^2 D \left (m^2+(3 n+8) m+3 \left (n^2+5 n+6\right )\right )\right ) x\right )dx}{b^2 d (m+n+3)}-\frac {(a+b x)^{m+2} (c+d x)^{n+1} (a d D (2 m+3 n+9)+b c D (m+3)-b C d (m+n+4))}{d (m+n+3)}}{b^3 d (m+n+4)}+\frac {D (a+b x)^{m+3} (c+d x)^{n+1}}{b^3 d (m+n+4)}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {\frac {\int (a+b x)^m (c+d x)^n \left (d^2 D (n+1) (m+2 n+6) a^3-b d (C d (n+1) (m+n+4)-c D (m+2) (m+3 n+6)) a^2+b^2 c (m+2) (c D (m+3)-C d (m+n+4)) a+A b^3 d^2 \left (m^2+(2 n+7) m+n^2+7 n+12\right )+b \left (\left (D \left (m^2+5 m+6\right ) c^2-C d (m+2) (m+n+4) c+B d^2 \left (m^2+(2 n+7) m+n^2+7 n+12\right )\right ) b^2+a d \left (c D (m+2) (m+3 n+6)-C d \left (m^2+(3 n+8) m+2 \left (n^2+6 n+8\right )\right )\right ) b+a^2 d^2 D \left (m^2+(3 n+8) m+3 \left (n^2+5 n+6\right )\right )\right ) x\right )dx}{d (m+n+3)}-\frac {(a+b x)^{m+2} (c+d x)^{n+1} (a d D (2 m+3 n+9)+b c D (m+3)-b C d (m+n+4))}{d (m+n+3)}}{b^3 d (m+n+4)}+\frac {D (a+b x)^{m+3} (c+d x)^{n+1}}{b^3 d (m+n+4)}\) |
\(\Big \downarrow \) 90 |
\(\displaystyle \frac {\frac {\left (a^3 d^2 D (n+1) (m+2 n+6)-\frac {(a d (n+1)+b c (m+1)) \left (a^2 d^2 D \left (m^2+m (3 n+8)+3 \left (n^2+5 n+6\right )\right )+a b d \left (c D (m+2) (m+3 n+6)-C d \left (m^2+m (3 n+8)+2 \left (n^2+6 n+8\right )\right )\right )+b^2 \left (B d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )+c^2 D \left (m^2+5 m+6\right )-c C d (m+2) (m+n+4)\right )\right )}{d (m+n+2)}-a^2 b d (C d (n+1) (m+n+4)-c D (m+2) (m+3 n+6))+a b^2 c (m+2) (c D (m+3)-C d (m+n+4))+A b^3 d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )\right ) \int (a+b x)^m (c+d x)^ndx+\frac {(a+b x)^{m+1} (c+d x)^{n+1} \left (a^2 d^2 D \left (m^2+m (3 n+8)+3 \left (n^2+5 n+6\right )\right )+a b d \left (c D (m+2) (m+3 n+6)-C d \left (m^2+m (3 n+8)+2 \left (n^2+6 n+8\right )\right )\right )+b^2 \left (B d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )+c^2 D \left (m^2+5 m+6\right )-c C d (m+2) (m+n+4)\right )\right )}{d (m+n+2)}}{d (m+n+3)}-\frac {(a+b x)^{m+2} (c+d x)^{n+1} (a d D (2 m+3 n+9)+b c D (m+3)-b C d (m+n+4))}{d (m+n+3)}}{b^3 d (m+n+4)}+\frac {D (a+b x)^{m+3} (c+d x)^{n+1}}{b^3 d (m+n+4)}\) |
\(\Big \downarrow \) 80 |
\(\displaystyle \frac {\frac {(c+d x)^n \left (\frac {b (c+d x)}{b c-a d}\right )^{-n} \left (a^3 d^2 D (n+1) (m+2 n+6)-\frac {(a d (n+1)+b c (m+1)) \left (a^2 d^2 D \left (m^2+m (3 n+8)+3 \left (n^2+5 n+6\right )\right )+a b d \left (c D (m+2) (m+3 n+6)-C d \left (m^2+m (3 n+8)+2 \left (n^2+6 n+8\right )\right )\right )+b^2 \left (B d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )+c^2 D \left (m^2+5 m+6\right )-c C d (m+2) (m+n+4)\right )\right )}{d (m+n+2)}-a^2 b d (C d (n+1) (m+n+4)-c D (m+2) (m+3 n+6))+a b^2 c (m+2) (c D (m+3)-C d (m+n+4))+A b^3 d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )\right ) \int (a+b x)^m \left (\frac {b c}{b c-a d}+\frac {b d x}{b c-a d}\right )^ndx+\frac {(a+b x)^{m+1} (c+d x)^{n+1} \left (a^2 d^2 D \left (m^2+m (3 n+8)+3 \left (n^2+5 n+6\right )\right )+a b d \left (c D (m+2) (m+3 n+6)-C d \left (m^2+m (3 n+8)+2 \left (n^2+6 n+8\right )\right )\right )+b^2 \left (B d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )+c^2 D \left (m^2+5 m+6\right )-c C d (m+2) (m+n+4)\right )\right )}{d (m+n+2)}}{d (m+n+3)}-\frac {(a+b x)^{m+2} (c+d x)^{n+1} (a d D (2 m+3 n+9)+b c D (m+3)-b C d (m+n+4))}{d (m+n+3)}}{b^3 d (m+n+4)}+\frac {D (a+b x)^{m+3} (c+d x)^{n+1}}{b^3 d (m+n+4)}\) |
\(\Big \downarrow \) 79 |
\(\displaystyle \frac {\frac {\frac {(a+b x)^{m+1} (c+d x)^{n+1} \left (a^2 d^2 D \left (m^2+m (3 n+8)+3 \left (n^2+5 n+6\right )\right )+a b d \left (c D (m+2) (m+3 n+6)-C d \left (m^2+m (3 n+8)+2 \left (n^2+6 n+8\right )\right )\right )+b^2 \left (B d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )+c^2 D \left (m^2+5 m+6\right )-c C d (m+2) (m+n+4)\right )\right )}{d (m+n+2)}+\frac {(a+b x)^{m+1} (c+d x)^n \left (\frac {b (c+d x)}{b c-a d}\right )^{-n} \operatorname {Hypergeometric2F1}\left (m+1,-n,m+2,-\frac {d (a+b x)}{b c-a d}\right ) \left (a^3 d^2 D (n+1) (m+2 n+6)-\frac {(a d (n+1)+b c (m+1)) \left (a^2 d^2 D \left (m^2+m (3 n+8)+3 \left (n^2+5 n+6\right )\right )+a b d \left (c D (m+2) (m+3 n+6)-C d \left (m^2+m (3 n+8)+2 \left (n^2+6 n+8\right )\right )\right )+b^2 \left (B d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )+c^2 D \left (m^2+5 m+6\right )-c C d (m+2) (m+n+4)\right )\right )}{d (m+n+2)}-a^2 b d (C d (n+1) (m+n+4)-c D (m+2) (m+3 n+6))+a b^2 c (m+2) (c D (m+3)-C d (m+n+4))+A b^3 d^2 \left (m^2+m (2 n+7)+n^2+7 n+12\right )\right )}{b (m+1)}}{d (m+n+3)}-\frac {(a+b x)^{m+2} (c+d x)^{n+1} (a d D (2 m+3 n+9)+b c D (m+3)-b C d (m+n+4))}{d (m+n+3)}}{b^3 d (m+n+4)}+\frac {D (a+b x)^{m+3} (c+d x)^{n+1}}{b^3 d (m+n+4)}\) |
(D*(a + b*x)^(3 + m)*(c + d*x)^(1 + n))/(b^3*d*(4 + m + n)) + (-(((b*c*D*( 3 + m) - b*C*d*(4 + m + n) + a*d*D*(9 + 2*m + 3*n))*(a + b*x)^(2 + m)*(c + d*x)^(1 + n))/(d*(3 + m + n))) + (((a^2*d^2*D*(m^2 + m*(8 + 3*n) + 3*(6 + 5*n + n^2)) + b^2*(c^2*D*(6 + 5*m + m^2) - c*C*d*(2 + m)*(4 + m + n) + B* d^2*(12 + m^2 + 7*n + n^2 + m*(7 + 2*n))) + a*b*d*(c*D*(2 + m)*(6 + m + 3* n) - C*d*(m^2 + m*(8 + 3*n) + 2*(8 + 6*n + n^2))))*(a + b*x)^(1 + m)*(c + d*x)^(1 + n))/(d*(2 + m + n)) + ((a^3*d^2*D*(1 + n)*(6 + m + 2*n) + a*b^2* c*(2 + m)*(c*D*(3 + m) - C*d*(4 + m + n)) + A*b^3*d^2*(12 + m^2 + 7*n + n^ 2 + m*(7 + 2*n)) - a^2*b*d*(C*d*(1 + n)*(4 + m + n) - c*D*(2 + m)*(6 + m + 3*n)) - ((b*c*(1 + m) + a*d*(1 + n))*(a^2*d^2*D*(m^2 + m*(8 + 3*n) + 3*(6 + 5*n + n^2)) + b^2*(c^2*D*(6 + 5*m + m^2) - c*C*d*(2 + m)*(4 + m + n) + B*d^2*(12 + m^2 + 7*n + n^2 + m*(7 + 2*n))) + a*b*d*(c*D*(2 + m)*(6 + m + 3*n) - C*d*(m^2 + m*(8 + 3*n) + 2*(8 + 6*n + n^2)))))/(d*(2 + m + n)))*(a + b*x)^(1 + m)*(c + d*x)^n*Hypergeometric2F1[1 + m, -n, 2 + m, -((d*(a + b *x))/(b*c - a*d))])/(b*(1 + m)*((b*(c + d*x))/(b*c - a*d))^n))/(d*(3 + m + n)))/(b^3*d*(4 + m + n))
3.1.34.3.1 Defintions of rubi rules used
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((a_) + (b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[(( a + b*x)^(m + 1)/(b*(m + 1)*(b/(b*c - a*d))^n))*Hypergeometric2F1[-n, m + 1 , m + 2, (-d)*((a + b*x)/(b*c - a*d))], x] /; FreeQ[{a, b, c, d, m, n}, x] && !IntegerQ[m] && !IntegerQ[n] && GtQ[b/(b*c - a*d), 0] && (RationalQ[m] || !(RationalQ[n] && GtQ[-d/(b*c - a*d), 0]))
Int[((a_) + (b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[(c + d*x)^FracPart[n]/((b/(b*c - a*d))^IntPart[n]*(b*((c + d*x)/(b*c - a*d))) ^FracPart[n]) Int[(a + b*x)^m*Simp[b*(c/(b*c - a*d)) + b*d*(x/(b*c - a*d) ), x]^n, x], x] /; FreeQ[{a, b, c, d, m, n}, x] && !IntegerQ[m] && !Integ erQ[n] && (RationalQ[m] || !SimplerQ[n + 1, m + 1])
Int[((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p _.), x_] :> Simp[b*(c + d*x)^(n + 1)*((e + f*x)^(p + 1)/(d*f*(n + p + 2))), x] + Simp[(a*d*f*(n + p + 2) - b*(d*e*(n + 1) + c*f*(p + 1)))/(d*f*(n + p + 2)) Int[(c + d*x)^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, n, p}, x] && NeQ[n + p + 2, 0]
Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))^(n_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Simp[c^p*(d + e*x)^(m + 2*p)*((f + g*x )^(n + 1)/(g*e^(2*p)*(m + n + 2*p + 1))), x] + Simp[1/(g*e^(2*p)*(m + n + 2 *p + 1)) Int[(d + e*x)^m*(f + g*x)^n*ExpandToSum[g*(m + n + 2*p + 1)*(e^( 2*p)*(a + b*x + c*x^2)^p - c^p*(d + e*x)^(2*p)) - c^p*(e*f - d*g)*(m + 2*p) *(d + e*x)^(2*p - 1), x], x], x] /; FreeQ[{a, b, c, d, e, f, g}, x] && IGtQ [p, 0] && !IntegerQ[m] && !IntegerQ[n] && NeQ[m + n + 2*p + 1, 0]
Int[(Px_)*((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> With[{q = Expon[Px, x], k = Coeff[Px, x, Expon[Px, x]]}, Simp[k*(a + b*x )^(m + q)*((c + d*x)^(n + 1)/(d*b^q*(m + n + q + 1))), x] + Simp[1/(d*b^q*( m + n + q + 1)) Int[(a + b*x)^m*(c + d*x)^n*ExpandToSum[d*b^q*(m + n + q + 1)*Px - d*k*(m + n + q + 1)*(a + b*x)^q - k*(b*c - a*d)*(m + q)*(a + b*x) ^(q - 1), x], x], x] /; NeQ[m + n + q + 1, 0]] /; FreeQ[{a, b, c, d, m, n}, x] && PolyQ[Px, x]
\[\int \left (b x +a \right )^{m} \left (d x +c \right )^{n} \left (D x^{3}+C \,x^{2}+B x +A \right )d x\]
\[ \int (a+b x)^m (c+d x)^n \left (A+B x+C x^2+D x^3\right ) \, dx=\int { {\left (\mathit {capitalD} x^{3} + C x^{2} + B x + A\right )} {\left (b x + a\right )}^{m} {\left (d x + c\right )}^{n} \,d x } \]
Exception generated. \[ \int (a+b x)^m (c+d x)^n \left (A+B x+C x^2+D x^3\right ) \, dx=\text {Exception raised: HeuristicGCDFailed} \]
\[ \int (a+b x)^m (c+d x)^n \left (A+B x+C x^2+D x^3\right ) \, dx=\int { {\left (D x^{3} + C x^{2} + B x + A\right )} {\left (b x + a\right )}^{m} {\left (d x + c\right )}^{n} \,d x } \]
\[ \int (a+b x)^m (c+d x)^n \left (A+B x+C x^2+D x^3\right ) \, dx=\int { {\left (D x^{3} + C x^{2} + B x + A\right )} {\left (b x + a\right )}^{m} {\left (d x + c\right )}^{n} \,d x } \]
Timed out. \[ \int (a+b x)^m (c+d x)^n \left (A+B x+C x^2+D x^3\right ) \, dx=\int {\left (a+b\,x\right )}^m\,{\left (c+d\,x\right )}^n\,\left (A+B\,x+C\,x^2+x^3\,D\right ) \,d x \]